""" -*- mode: python; coding: utf-8; -*-

    Copyright 2008 Asier Aguirre <asier.aguirre@gmail.com>
    This file is part of Intromit.

    Intromit is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    Intromit is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with Intromit.  If not, see <http://www.gnu.org/licenses/>.
"""

import unittest, python_basic, python_members, python_methods, python_misc, python_doc
import python_obj, python_runner, sys

if __name__ == '__main__':

    suite=unittest.TestSuite()
    suite.addTest(unittest.TestLoader().loadTestsFromTestCase(python_basic.test_1_basic))
    suite.addTest(unittest.TestLoader().loadTestsFromTestCase(python_members.test_2_members))
    suite.addTest(unittest.TestLoader().loadTestsFromTestCase(python_methods.test_3_methods))
    suite.addTest(unittest.TestLoader().loadTestsFromTestCase(python_misc.test_4_misc))
    suite.addTest(unittest.TestLoader().loadTestsFromTestCase(python_obj.test_5_obj))
    suite.addTest(unittest.TestLoader().loadTestsFromTestCase(python_doc.test_6_doc))
    result=python_runner.BasicTestRunner(iterations=len(sys.argv)>1 and sys.argv[1] or 1,
	stream=len(sys.argv)>2 and open(sys.argv[2], "a") or sys.stderr).run(suite)
    sys.exit(not result.wasSuccessful())
